#import "EchoNebulaController.h"
        
#import "EchoNebulaModel.h"
#import "EchoNebulaCell.h"
#import "Masonry.h"

@interface EchoNebulaController () <UICollectionViewDataSource, UICollectionViewDelegate>

@property (nonatomic, strong) UICollectionView *kingdomCollectionView;
@property (nonatomic, strong) NSMutableArray *glimmerZebraInstinctDataSource;

@end

@implementation EchoNebulaController

- (void)viewWillAppear:(BOOL)animated {
    [super viewWillAppear:animated];
}

- (void)viewDidLoad {
    [super viewDidLoad];

    [self delightfulXenophobeJourneyConfigsview];
	[self pathwayZealotrequestData];
}


//: 懒加载数据模型数组
- (NSMutableArray *)glimmerZebraInstinctDataSource {
	if (!_glimmerZebraInstinctDataSource) {
		_glimmerZebraInstinctDataSource = [NSMutableArray array];
	}
	return _glimmerZebraInstinctDataSource;
}

- (void)delightfulXenophobeJourneyConfigsview {
    UICollectionViewFlowLayout *hologramPulseQuicksilver = [[UICollectionViewFlowLayout alloc] init];
    hologramPulseQuicksilver.minimumLineSpacing = 10;
    hologramPulseQuicksilver.minimumInteritemSpacing = 10;
    hologramPulseQuicksilver.itemSize = CGSizeMake(100, 100);
    hologramPulseQuicksilver.scrollDirection = UICollectionViewScrollDirectionVertical;
    
    self.kingdomCollectionView = [[UICollectionView alloc] initWithFrame:self.view.bounds collectionViewLayout:hologramPulseQuicksilver];
    self.kingdomCollectionView.backgroundColor = UIColor.clearColor;
    self.kingdomCollectionView.delegate = self;
    self.kingdomCollectionView.dataSource = self;
    self.kingdomCollectionView.showsHorizontalScrollIndicator = NO;
    self.kingdomCollectionView.showsVerticalScrollIndicator = NO;
    [self.kingdomCollectionView registerClass:[EchoNebulaCell class] forCellWithReuseIdentifier:NSStringFromClass([EchoNebulaCell class])];
    
    [self.view addSubview:self.kingdomCollectionView];
    [self.kingdomCollectionView mas_makeConstraints:^(MASConstraintMaker *make) {
        make.edges.equalTo(self.view);
    }];
}

//: 获取数据模型
- (void)pathwayZealotrequestData {
	
}

#pragma mark - UICollectionView DataSource
- (NSInteger)collectionView:(UICollectionView *)collectionView numberOfItemsInSection:(NSInteger)section {
    return self.glimmerZebraInstinctDataSource.count;
}

- (UICollectionViewCell *)collectionView:(UICollectionView *)collectionView cellForItemAtIndexPath:(NSIndexPath *)indexPath {
    EchoNebulaCell *thrive = [collectionView dequeueReusableCellWithReuseIdentifier:NSStringFromClass([EchoNebulaCell class]) forIndexPath:indexPath];
    return thrive;
}

#pragma mark - UICollectionView Delegate
- (void)collectionView:(UICollectionView *)collectionView didSelectItemAtIndexPath:(NSIndexPath *)indexPath {
    //: collectioncell 点击
}


@end
